﻿using System;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace ProjetoComperio.DataLayer.Entities
{
    public class User
    {
        [Required(ErrorMessageResourceName = "Required", ErrorMessageResourceType = typeof(ErrorMessages))]
        public virtual int UserID { get; set; }

        [Required(ErrorMessageResourceName = "Required", ErrorMessageResourceType = typeof(ErrorMessages))]
        [DisplayName("Usuário")]
        public virtual String UserName { get; set; }

        [Required(ErrorMessageResourceName = "Required", ErrorMessageResourceType = typeof(ErrorMessages))]
        [DisplayName("Senha")]
        public virtual String Password { get; set; }

        public virtual String PasswordQuestion { get; set; }
        public virtual String PasswordAnswer { get; set; }
        public virtual Boolean IsApproved { get; set; }
        public virtual DateTime LastActivityDate { get; set; }
        public virtual DateTime LastLoginDate { get; set; }
        public virtual DateTime LastPasswordChangedDate { get; set; }
        public virtual DateTime CreationDate { get; set; }
        public virtual Boolean IsOnLine { get; set; }
        public virtual Boolean IsLockedOut { get; set; }
        public virtual DateTime LastLockedOut { get; set; }
        public virtual DateTime LastLockedOutDate { get; set; }
        public virtual int FailedPassswordAttemptCount { get; set; }
        public virtual DateTime FailedPasswordAttemptWindowStart { get; set; }
        public virtual int FailedPasswordAnswerAttemptCount { get; set; }
        public virtual DateTime FailedPasswordAnswerAttemptWindowStart { get; set; }
        public virtual String Email { get; set; }
        public virtual int RoleID { get; set; }
        public virtual String Comment { get; set; }
        public virtual int PersonID { get; set; }
    }
}
